//
//  BankFooterView.m
//  GLGW_Shoping
//
//  Created by whx on 2018/12/5.
//  Copyright © 2018年 yang. All rights reserved.
//

#import "BankFooterView.h"

@interface BankFooterView ()
{
    GLGWButton *bottomBtn;
}
@end

@implementation BankFooterView

- (instancetype)initWithReuseIdentifier:(NSString *)reuseIdentifier
{
    if (self = [super initWithReuseIdentifier:reuseIdentifier]) {
        GLGWButton *btn = [[GLGWButton alloc] initWithTitle:@"申请提现" titleLableFont:SYSTEMFONT(16) titleLableColor:[UIColor colorWithHexString:@"#FFFFFF"] inSuperView:self.contentView];
        [btn mas_makeConstraints:^(MASConstraintMaker *make) {
            make.left.equalTo(self.contentView).offset(kWidthProportion_In_iPhoneTriploid(15));
            make.right.equalTo(self.contentView).offset(-kWidthProportion_In_iPhoneTriploid(15));
            make.bottom.equalTo(self.contentView.mas_bottom);
            make.height.equalTo(@(kHeightProportion_In_iPhoneTriploid(44)));
        }];
        [btn setBackgroundImage:[UIImage imageWithStartColor:[UIColor colorWithHexString:@"#A89A60" alpha:1] endColor:[UIColor colorWithHexString:@"#A89A60" alpha:0.8]] forState:UIControlStateNormal];
        [btn addTarget:self action:@selector(btnAction:) forControlEvents:UIControlEventTouchUpInside];
        btn.layer.masksToBounds = YES;
        btn.layer.cornerRadius = kHeightProportion_In_iPhoneTriploid(22);
        bottomBtn = btn;

    }
    return self;
}

- (void)setBtnStr:(NSString *)btnStr
{
    _btnStr = btnStr;
    [bottomBtn setTitle:btnStr forState:UIControlStateNormal];
    
}

- (void)btnAction:(GLGWButton *)sender
{
    if (self.BlockApplyWithDraw) {
        self.BlockApplyWithDraw(sender);
    }
}

@end
